package us.codecraft.webmagic.pipeline;

import us.codecraft.webmagic.Task;
import us.codecraft.webmagic.model.BaseDO;
import us.codecraft.webmagic.utils.JSONUtils;

/**
 * Write results in console.<br>
 * Usually used in test.
 *
 * @author code4crafter@gmail.com <br>
 * @since 0.1.0
 */
public class ConsolePipeline implements Pipeline {

    @Override
    public void process(BaseDO baseDO, Task task) {
        System.out.println(JSONUtils.objectToStringNonEx(baseDO));
    }
}
